﻿using Decoration.Models.Models;
using Microsoft.EntityFrameworkCore;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Decoration.Models
{
    public static class ModelBuilderExtensions
    {
        public static void Seed(this ModelBuilder modelBuilder)
        {
            // 字典类型
            modelBuilder.Entity<Base_DictType>().HasData(
                new Base_DictType()
                {
                    Id = 1,
                    DictTypeName = "常规状态",
                    CreateTime = DateTime.Now,
                    Status = 1
                },
                new Base_DictType()
                {
                    Id = 2,
                    DictTypeName = "部门",
                    CreateTime = DateTime.Now,
                    Status = 1
                },
                new Base_DictType()
                {
                    Id = 3,
                    DictTypeName = "项目完成状态",
                    CreateTime = DateTime.Now,
                    Status = 1
                },
                new Base_DictType()
                {
                    Id = 4,
                    DictTypeName = "验收状态",
                    CreateTime = DateTime.Now,
                    Status = 1
                },
                new Base_DictType()
                {
                    Id = 5,
                    DictTypeName = "工序状态",
                    CreateTime = DateTime.Now,
                    Status = 1
                },
                new Base_DictType()
                {
                    Id = 6,
                    DictTypeName = "客户类型",
                },
                new Base_DictType()
                {
                    Id = 7,
                    DictTypeName = "订单类型",
                },
                new Base_DictType()
                {
                    Id = 8,
                    DictTypeName = "审批状态",
                },
                new Base_DictType()
                {
                    Id = 9,
                    DictTypeName = "订单项目状态"
                }
            );

            // 字典信息
            modelBuilder.Entity<Base_DictInfo>().HasData(
                   // 正常状态
                   new Base_DictInfo()
                   {
                       Id = 1,
                       DictTypeId = 1,
                       DictName = "正常",
                       DictValue = 1,
                       DictOrder = 1,
                   },
                   new Base_DictInfo()
                   {
                       Id = 2,
                       DictTypeId = 1,
                       DictName = "删除",
                       DictValue = 0,
                       DictOrder = 2,
                   },
                   new Base_DictInfo()
                   {
                       Id = 3,
                       DictTypeId = 1,
                       DictName = "禁用",
                       DictValue = -1,
                       DictOrder = 3,
                   },
                   // 部门
                   new Base_DictInfo()
                   {
                       Id = 4,
                       DictTypeId = 2,
                       DictName = "总经理办公室",
                       DictValue = 1,
                       DictOrder = 1,
                   },
                   new Base_DictInfo()
                   {
                       Id = 5,
                       DictTypeId = 2,
                       DictName = "销售部",
                       DictValue = 2,
                       DictOrder = 2,
                   },
                   new Base_DictInfo()
                   {
                       Id = 6,
                       DictTypeId = 2,
                       DictName = "工程部",
                       DictValue = 3,
                       DictOrder = 3,
                   },
                   new Base_DictInfo()
                   {
                       Id = 7,
                       DictTypeId = 2,
                       DictName = "设计部",
                       DictValue = 4,
                       DictOrder = 4,
                   },

                   // 项目完成状态
                   new Base_DictInfo()
                   {
                       Id = 8,
                       DictTypeId = 3,
                       DictName = "筹备中",
                       DictValue = 0,
                       DictOrder = 1,
                   },
                   new Base_DictInfo()
                   {
                       Id = 9,
                       DictTypeId = 3,
                       DictName = "进行中",
                       DictValue = 1,
                       DictOrder = 2,
                   },
                   new Base_DictInfo()
                   {
                       Id = 10,
                       DictTypeId = 3,
                       DictName = "已完成",
                       DictValue = 2,
                       DictOrder = 3,
                   },

                   //验收状态
                   new Base_DictInfo()
                   {
                       Id = 11,
                       DictTypeId = 4,
                       DictName = "未验收",
                       DictValue = 1,
                       DictOrder = 1,
                   },
                   new Base_DictInfo()
                   {
                       Id = 12,
                       DictTypeId = 4,
                       DictName = "通过",
                       DictValue = 2,
                       DictOrder = 2,
                   },
                   new Base_DictInfo()
                   {
                       Id = 13,
                       DictTypeId = 4,
                       DictName = "未通过",
                       DictValue = 3,
                       DictOrder = 3,
                   },

                   // 工序状态
                   new Base_DictInfo()
                   {
                       Id = 14,
                       DictTypeId = 5,
                       DictName = "等待中",
                       DictValue = 0,
                       DictOrder = 1,
                   },
                   new Base_DictInfo()
                   {
                       Id = 15,
                       DictTypeId = 5,
                       DictName = "进行中",
                       DictValue = 1,
                       DictOrder = 2,
                   },
                   new Base_DictInfo()
                   {
                       Id = 16,
                       DictTypeId = 5,
                       DictName = "已完成",
                       DictValue = 2,
                       DictOrder = 3,
                   },
                   new Base_DictInfo()
                   {
                       Id = 17,
                       DictTypeId = 5,
                       DictName = "延期",
                       DictValue = 3,
                       DictOrder = 4,
                   },

                   // 客户类型
                   new Base_DictInfo()
                   {
                       Id = 18,
                       DictTypeId = 6,
                       DictName = "普通客户",
                       DictValue = 1,
                       DictOrder = 1,
                   },
                   new Base_DictInfo()
                   {
                       Id = 19,
                       DictTypeId = 6,
                       DictName = "VIP客户",
                       DictValue = 2,
                       DictOrder = 2,
                   },

                   // 订单类型
                   new Base_DictInfo()
                   {
                       Id = 20,
                       DictTypeId = 7,
                       DictName = "普通订单",
                       DictValue = 1,
                       DictOrder = 1,
                   },
                   new Base_DictInfo()
                   {
                       Id = 21,
                       DictTypeId = 7,
                       DictName = "VIP订单",
                       DictValue = 2,
                       DictOrder = 2,
                   },
                   new Base_DictInfo()
                   {
                       Id = 22,
                       DictTypeId = 8,
                       DictName = "未审核",
                       DictValue = 1,
                       DictOrder = 1,
                   },
                   new Base_DictInfo()
                   {
                       Id = 23,
                       DictTypeId = 8,
                       DictName = "审批中",
                       DictValue = 2,
                       DictOrder = 2,
                   },
                   new Base_DictInfo()
                   {
                       Id = 24,
                       DictTypeId = 8,
                       DictName = "通过",
                       DictValue = 3,
                       DictOrder = 3,
                   },
                   new Base_DictInfo()
                   {
                       Id = 25,
                       DictTypeId = 8,
                       DictName = "驳回",
                       DictValue = 4,
                       DictOrder = 4,
                   },
                   new Base_DictInfo()
                   {
                       Id = 26,
                       DictTypeId = 9,
                       DictName = "未成立",
                       DictValue = 0,
                       DictOrder = 1,
                   },
                   new Base_DictInfo()
                   {
                       Id = 27,
                       DictTypeId = 9,
                       DictName = "进行中",
                       DictValue = 1,
                       DictOrder = 2,
                   },
                     new Base_DictInfo()
                     {
                      Id = 28,
                      DictTypeId = 5,
                      DictName = "请求延期中",
                      DictValue = 5,
                      DictOrder = 4,
                    },
                   new Base_DictInfo()
                    {
                      Id = 29,
                      DictTypeId = 5,
                      DictName = "请求转移中",
                      DictValue = 4,
                      DictOrder = 3,
                    }
            );

            // 用户信息
            modelBuilder.Entity<Base_UserInfo>().HasData(
                new Base_UserInfo()
                {
                    Id = 1,
                    UserName = "管理员",
                    Sex = "男",
                    Tel = "13058519846",
                    Email = "2386707006@qq.com",
                    IdCard = "431223200501200032",
                    DeptId = 1,
                },
                new Base_UserInfo()
                {
                    Id = 2,
                    UserName = "李正心",
                    Sex = "男",
                    Tel = "18723879090",
                    Email = "fass23@ww.com",
                    IdCard = "434323199802030091",
                    DeptId = 1,
                },
                new Base_UserInfo()
                {
                    Id = 3,
                    UserName = "张三三",
                    Sex = "男",
                    Tel = "13800001111",
                    Email = "zhangsan@sohu.com",
                    IdCard = "434323199702030009",
                    DeptId = 2,
                },
                 new Base_UserInfo()
                {
                    Id = 4,
                    UserName = "华芳",
                    Sex = "女",
                    Tel = "13811183122",
                    Email = "liudehua@ww2.com",
                    IdCard = "430523199802030092",
                    DeptId = 1,
                },
                new Base_UserInfo()
                {
                    Id = 5,
                    UserName = "李闯",
                    Sex = "男",
                    Tel = "13212345678",
                    Email = "lisi@163.com",
                    IdCard = "434323199802030091",
                    DeptId = 1,
                },
                new Base_UserInfo()
                {
                    Id = 6,
                    UserName = "王阳",
                    Sex = "男",
                    Tel = "13113254673",
                    Email = "wanyan@778.com",
                    IdCard = "434323199802030091",
                    DeptId = 2,
                },
                new Base_UserInfo()
                {
                    Id = 7,
                    UserName = "童鱼",
                    Sex = "男",
                    Tel = "13287654312",
                    Email = "sss@163.com",
                    IdCard = "434323199802030091",
                    DeptId = 3
                },
                new Base_UserInfo()
                {
                    Id = 8,
                    UserName = "廖洪杰",
                    Sex = "男",
                    Tel = "13214325670",
                    Email = "lisiqq@163.com",
                    IdCard = "434323199802030091",
                    DeptId = 3,
                },
                new Base_UserInfo()
                {
                    Id = 9,
                    UserName = "肖延吉",
                    Sex = "男",
                    Tel = "13212345590",
                    Email = "qqshou@163.com",
                    IdCard = "434323199802030091",
                    DeptId = 1,
                },
                new Base_UserInfo()
                {
                    Id = 10,
                    UserName = "黄鑫",
                    Sex = "男",
                    Tel = "13811183880",
                    Email = "deng.org@163.com",
                    IdCard = "434323199802030091",
                    DeptId = 1,
                }
            );

            // 登录信息
            modelBuilder.Entity<Base_LoginInfo>().HasData(
                new Base_LoginInfo()
                {
                    Id = 1,
                    UserId = 1,
                    LoginName = "admin",
                    LoginPwd = "123456",
                    LoginCount = 1,
                    LoginLastTime = DateTime.Now,
                    ProfilePhoto = "avater.png"
                },
                new Base_LoginInfo()
                {
                    Id = 2,
                    UserId = 2,
                    LoginName = "lizhengxin",
                    LoginPwd = "123456",
                    LoginCount = 1,
                    LoginLastTime = DateTime.Now,
                    ProfilePhoto = "avater.png"
                },
                new Base_LoginInfo()
                {
                    Id = 3,
                    UserId = 3,
                    LoginName = "zhangsansan",
                    LoginPwd = "123456",
                    LoginCount = 1,
                    LoginLastTime = DateTime.Now,
                    ProfilePhoto = "avater.png"
                },
                new Base_LoginInfo()
                {
                    Id = 4,
                    UserId = 4,
                    LoginName = "huafang",
                    LoginPwd = "123456",
                    LoginCount = 1,
                    LoginLastTime = DateTime.Now,
                    ProfilePhoto = "avater.png"
                },
                new Base_LoginInfo()
                {
                    Id = 5,
                    UserId = 5,
                    LoginName = "lichuang",
                    LoginPwd = "123456",
                    LoginCount = 1,
                    LoginLastTime = DateTime.Now,
                    ProfilePhoto = "avater.png"
                },
                new Base_LoginInfo()
                {
                    Id = 6,
                    UserId = 6,
                    LoginName = "wangyang",
                    LoginPwd = "123456",
                    LoginCount = 1,
                    LoginLastTime = DateTime.Now,
                    ProfilePhoto = "avater.png"
                },
                new Base_LoginInfo()
                {
                    Id =7,
                    UserId = 7,
                    LoginName = "tongyu",
                    LoginPwd = "123456",
                    LoginCount = 1,
                    LoginLastTime = DateTime.Now,
                    ProfilePhoto = "avater.png"
                },
                new Base_LoginInfo()
                {
                    Id = 8,
                    UserId = 8,
                    LoginName = "liaohongjie",
                    LoginPwd = "123456",
                    LoginCount = 1,
                    LoginLastTime = DateTime.Now,
                    ProfilePhoto = "avater.png"
                },
                new Base_LoginInfo()
                {
                    Id = 9,
                    UserId = 9,
                    LoginName = "xiaoyanji",
                    LoginPwd = "123456",
                    LoginCount = 1,
                    LoginLastTime = DateTime.Now,
                    ProfilePhoto = "avater.png"
                },
                new Base_LoginInfo()
                {
                    Id = 10,
                    UserId = 10,
                    LoginName = "huangxin",
                    LoginPwd = "123456",
                    LoginCount = 1,
                    LoginLastTime = DateTime.Now,
                    ProfilePhoto = "avater.png"
                }
            );

            // 角色信息
            modelBuilder.Entity<Base_RoleInfo>().HasData(
                new Base_RoleInfo()
                {
                    Id = 1,
                    RoleName = "管理员",
                    RoleValue = 1,
                    Remark = "掌管一切的神"
                },
                new Base_RoleInfo()
                {
                    Id = 2,
                    RoleName = "项目负责人",
                    RoleValue = 2,
                    Remark = "掌管项目的神"
                },
                new Base_RoleInfo()
                {
                    Id = 3,
                    RoleName = "销售",
                    RoleValue = 3,
                    Remark = "掌管money的神"
                },
                new Base_RoleInfo()
                {
                    Id = 4,
                    RoleName = "普通员工",
                    RoleValue = 4,
                    Remark = "掌管工序的神"
                },
                 new Base_RoleInfo()
                 {
                     Id = 5,
                     RoleName = "财务",
                     RoleValue = 5,
                     Remark = "财务审批"
                 },
                 new Base_RoleInfo()
                 {
                     Id = 6,
                     RoleName = "部门审批",
                     RoleValue = 6,
                     Remark = "部门审批"
                 }
            );

            // 菜单信息
            modelBuilder.Entity<Base_MenuInfo>().HasData(
                new Base_MenuInfo()
                {
                    Id = 1,
                    MenuName = "用户管理",
                    MenuIcon = "User",
                    IsShow = 1,
                    MenuOrder = 1,
                },
                new Base_MenuInfo()
                {
                    Id = 2,
                    MenuName = "用户列表",
                    MenuUrl = "/user",
                    MenuIcon = "List",
                    PId = 1,
                    IsShow = 1,
                    MenuOrder = 1,
                },
                new Base_MenuInfo()
                {
                    Id = 3,
                    MenuName = "菜单管理",
                    MenuIcon = "Menu",
                    IsShow = 1,
                    MenuOrder = 2,
                },
                new Base_MenuInfo()
                {
                    Id = 4,
                    MenuName = "菜单列表",
                    MenuUrl = "/menu",
                    MenuIcon = "List",
                    PId = 3,
                    IsShow = 1,
                    MenuOrder = 1,
                },
                new Base_MenuInfo()
                {
                    Id = 5,
                    MenuName = "角色管理",
                    MenuIcon = "List",
                    IsShow = 1,
                    MenuOrder = 3,
                },
                new Base_MenuInfo()
                {
                    Id = 6,
                    MenuName = "角色列表",
                    MenuUrl = "/role",
                    MenuIcon = "List",
                    PId = 5,
                    IsShow = 1,
                    MenuOrder = 1,
                },
                new Base_MenuInfo()
                {
                    Id = 7,
                    MenuName = "字典管理",
                    MenuIcon = "Notebook",
                    IsShow = 1,
                    MenuOrder = 4,
                },
                new Base_MenuInfo()
                {
                    Id = 8,
                    MenuName = "字典列表",
                    MenuUrl = "/dict",
                    MenuIcon = "List",
                    PId = 7,
                    IsShow = 1,
                    MenuOrder = 1,
                },
                new Base_MenuInfo()
                {
                    Id = 9,
                    MenuName = "业务管理",
                    MenuIcon = "Brush",
                    IsShow = 1,
                    MenuOrder = 5
                },
                new Base_MenuInfo()
                {
                    Id = 10,
                    MenuName = "业务列表",
                    MenuUrl = "/business",
                    MenuIcon = "List",
                    PId = 9,
                    IsShow = 1,
                    MenuOrder = 1
                },
                new Base_MenuInfo()
                {
                    Id = 11,
                    MenuName = "工序列表",
                    MenuUrl = "/procedure",
                    MenuIcon = "List",
                    PId = 9,
                    IsShow = 1,
                    MenuOrder = 2
                },
                new Base_MenuInfo()
                {
                    Id = 12,
                    MenuName = "订单管理",
                    MenuIcon = "Checked",
                    IsShow = 1,
                    MenuOrder = 6
                },
                new Base_MenuInfo()
                {
                    Id = 13,
                    MenuName = "订单列表",
                    MenuUrl = "/order",
                    MenuIcon = "List",
                    PId = 12,
                    IsShow = 1,
                    MenuOrder = 1
                },
                new Base_MenuInfo()
                {
                    Id = 14,
                    MenuName = "我的订单",
                    MenuUrl = "/myOrder",
                    MenuIcon = "List",
                    PId = 12,
                    IsShow = 1,
                    MenuOrder = 2
                },
                new Base_MenuInfo()
                {
                    Id = 15,
                    MenuName = "我的审批",
                    MenuUrl = "/myOrderApproval",
                    MenuIcon = "List",
                    PId = 12,
                    IsShow = 1,
                    MenuOrder = 3
                },
                new Base_MenuInfo()
                {
                    Id = 16,
                    MenuName = "项目管理",
                    MenuIcon = "DataAnalysis",
                    IsShow = 1,
                    MenuOrder = 7
                },
                new Base_MenuInfo()
                {
                    Id = 17,
                    MenuName = "项目列表",
                    MenuUrl = "/project",
                    MenuIcon = "List",
                    PId = 16,
                    IsShow = 1,
                    MenuOrder = 1
                },
                new Base_MenuInfo()
                {
                    Id = 18,
                    MenuName = "我的项目",
                    MenuUrl = "/myProject",
                    MenuIcon = "List",
                    PId = 16,
                    IsShow = 1,
                    MenuOrder = 2
                },
                new Base_MenuInfo()
                {
                    Id = 19,
                    MenuName = "商品管理",
                    MenuIcon = "Shop",
                    IsShow = 1,
                    MenuOrder = 8
                },
                new Base_MenuInfo()
                {
                    Id = 20,
                    MenuName = "商品列表",
                    MenuUrl = "/productinfo",
                    MenuIcon = "List",
                    PId = 19,
                    IsShow = 1,
                    MenuOrder = 1
                },
                new Base_MenuInfo()
                {
                    Id = 21,
                    MenuName = "审批管理",
                    MenuIcon = "List",
                    IsShow = 1,
                    MenuOrder = 9
                },
                new Base_MenuInfo()
                {
                    Id = 22,
                    MenuName = "审批列表",
                    MenuUrl = "/approval",
                    MenuIcon = "List",
                    PId = 21,
                    IsShow = 1,
                    MenuOrder = 1
                },
                new Base_MenuInfo()
                {
                    Id = 23,
                    MenuName = "我的审批",
                    MenuUrl = "/myapproval",
                    MenuIcon = "List",
                    PId = 21,
                    IsShow = 1,
                    MenuOrder = 2
                },
                new Base_MenuInfo()
                {
                    Id = 24,
                    MenuName = "审批节点",
                    MenuUrl = "/approvalNode",
                    MenuIcon = "List",
                    PId = 21,
                    IsShow = 1,
                    MenuOrder = 3
                },
                new Base_MenuInfo()
                {
                    Id = 25,
                    MenuName = "任务管理",
                    MenuIcon = "WindPower",
                    IsShow = 1,
                    MenuOrder = 10
                },
                new Base_MenuInfo()
                {
                    Id = 26,
                    MenuName = "任务列表",
                    MenuUrl = "/task",
                    MenuIcon = "List",
                    PId = 25,
                    IsShow = 1,
                    MenuOrder = 1
                },
                new Base_MenuInfo()
                {
                    Id = 27,
                    MenuName = "我的任务",
                    MenuUrl = "/myTask",
                    MenuIcon = "List",
                    PId = 25,
                    IsShow = 1,
                    MenuOrder = 2
                },
                new Base_MenuInfo()
                {
                    Id = 28,
                    MenuName = "延期申请",
                    MenuUrl = "/delay",
                    MenuIcon = "List",
                    PId = 25,
                    IsShow = 1,
                    MenuOrder= 3
                },
                new Base_MenuInfo()
                {
                    Id = 29,
                    MenuName = "延期审批",
                    MenuUrl = "/delayApproval",
                    MenuIcon = "List",
                    PId = 16,
                    IsShow = 1,
                    MenuOrder = 3
                },
                new Base_MenuInfo()
                {
                    Id = 30,
                    MenuName = "任务转移申请",
                    MenuUrl = "/transfer",
                    MenuIcon = "List",
                    PId = 25,
                    IsShow = 1,
                    MenuOrder = 4
                },
                new Base_MenuInfo()
                {
                    Id = 31,
                    MenuName = "任务转移审批",
                    MenuUrl = "/transferApproval",
                    MenuIcon = "List",
                    PId = 16,
                    IsShow = 1,
                    MenuOrder = 4
                }
            );

            // 角色菜单
            modelBuilder.Entity<Base_RoleMenu>().HasData(
                new Base_RoleMenu()
                {
                    Id = 1,
                    RoleId = 1,
                    MenuId = 2,
                },
                new Base_RoleMenu()
                {
                    Id = 2,
                    RoleId = 1,
                    MenuId = 4,
                },
                new Base_RoleMenu()
                {
                    Id = 3,
                    RoleId = 1,
                    MenuId = 6,
                },
                new Base_RoleMenu()
                {
                    Id = 4,
                    RoleId = 1,
                    MenuId = 8,
                },
                new Base_RoleMenu()
                {
                    Id = 5,
                    RoleId = 1,
                    MenuId = 10,
                },
                new Base_RoleMenu()
                {
                    Id = 6,
                    RoleId = 1,
                    MenuId = 11,
                },
                new Base_RoleMenu()
                {
                    Id = 7,
                    RoleId = 1,
                    MenuId = 13,
                },
                new Base_RoleMenu()
                {
                    Id = 8,
                    RoleId = 1,
                    MenuId = 14,
                },
                new Base_RoleMenu()
                {
                    Id = 9,
                    RoleId = 1,
                    MenuId = 15,
                },
                new Base_RoleMenu()
                {
                    Id = 10,
                    RoleId = 1,
                    MenuId = 17,
                },
                new Base_RoleMenu()
                {
                    Id = 11,
                    RoleId = 1,
                    MenuId = 18,
                },
                new Base_RoleMenu()
                {
                    Id = 12,
                    RoleId = 1,
                    MenuId = 20,
                },
                new Base_RoleMenu()
                {
                    Id = 13,
                    RoleId = 1,
                    MenuId = 22,
                },
                new Base_RoleMenu()
                {
                    Id = 14,
                    RoleId = 1,
                    MenuId = 23,
                },
                new Base_RoleMenu()
                {
                    Id = 15,
                    RoleId = 1,
                    MenuId = 24,
                },
                new Base_RoleMenu()
                {
                    Id = 16,
                    RoleId = 1,
                    MenuId = 26,
                },
                new Base_RoleMenu()
                {
                    Id = 17,
                    RoleId = 1,
                    MenuId = 27,
                },
                new Base_RoleMenu()
                {
                    Id = 18,
                    RoleId = 1,
                    MenuId = 28,
                },
                new Base_RoleMenu()
                {
                    Id = 19,
                    RoleId = 1,
                    MenuId = 29,
                }
            );

            // 用户角色
            modelBuilder.Entity<Base_UserRole>().HasData(
                new Base_UserRole()
                {
                    Id = 1,
                    UserId = 1,
                    RoleId = 1,
                }
            );

            // 业务
            modelBuilder.Entity<BusinessInfo>().HasData(
                new BusinessInfo()
                {
                    Id = 1,
                    BusinessName = "沙发定制",
                    BusinessDesc = "沙发定制描述",
                },
                new BusinessInfo()
                {
                    Id = 2,
                    BusinessName = "全屋定制",
                    BusinessDesc = "全屋全包，装修定制",
                },
                new BusinessInfo()
                {
                    Id = 3,
                    BusinessName = "半包定制",
                    BusinessDesc = "半包定制描述",
                }
            );

            // 客户
            modelBuilder.Entity<CustomerInfo>().HasData(
                new CustomerInfo()
                {
                    Id = 1,
                    CustomerName = "华正商贸",
                    CustomerType = 1,
                    Linkman = "李华正",
                    Desc = "认证对待",
                    Tel = "13850504320",
                    Password = "123456",
                }, new CustomerInfo()
                {
                    Id = 2,
                    CustomerName = "强强KTV",
                    CustomerType = 1,
                    Linkman = "张三",
                    Desc = "认证对待",
                    Tel = "13834099878",
                    Password = "123456",
                },
                new CustomerInfo()
                {
                    Id = 3,
                    CustomerName = "咪咪花店",
                    CustomerType = 2,
                    Linkman = "许慧",
                    Desc = "认证对待",
                    Tel = "13890908782",
                    Password = "123456",
                },
                new CustomerInfo()
                {
                    Id = 4,
                    CustomerName = "宏正书店",
                    CustomerType = 1,
                    Linkman = "章志成",
                    Desc = "认证对待",
                    Tel = "13856561324",
                    Password = "123456",
                },
                new CustomerInfo()
                {
                    Id = 5,
                    CustomerName = "艾薇科技",
                    CustomerType = 2,
                    Linkman = "廖化",
                    Desc = "认证对待",
                    Tel = "18098096452",
                    Password = "123456",
                }
            );

            // 工序
            modelBuilder.Entity<ProcedureInfo>().HasData(
                new ProcedureInfo()
                {
                    Id = 1,
                    BusinessId = 1,
                    ProcedureName = "客户洽淡",
                    ProcedureDesc = "要与客户进行方方面面的交谈",
                    ProcedureOrder = 1,
                },
                new ProcedureInfo()
                {
                    Id = 2,
                    BusinessId = 1,
                    ProcedureName = "设计初步方案",
                    ProcedureDesc = "要设计出顾客满意的方案",
                    ProcedureOrder = 2,
                },
                new ProcedureInfo()
                {
                    Id = 3,
                    BusinessId = 1,
                    ProcedureName = "现场环境确认",
                    ProcedureDesc = "确认现场施工环境，丈量面积等",
                    ProcedureOrder = 3,
                },
                new ProcedureInfo()
                {
                    Id = 4,
                    BusinessId = 1,
                    ProcedureName = "沙发询价",
                    ProcedureDesc = "询问沙发的价格",
                    ProcedureOrder = 4,
                },
                new ProcedureInfo()
                {
                    Id = 5,
                    BusinessId = 1,
                    ProcedureName = "抱枕询价",
                    ProcedureDesc = "询问抱枕的价格",
                    ProcedureOrder = 5,
                },
                new ProcedureInfo()
                {
                    Id = 6,
                    BusinessId = 1,
                    ProcedureName = "饰品询价",
                    ProcedureDesc = "询问饰品的价格",
                    ProcedureOrder = 6,
                },
                new ProcedureInfo()
                {
                    Id = 7,
                    BusinessId = 1,
                    ProcedureName = "编辑物品报价单",
                    ProcedureDesc = "对要购买的物品进行汇总报价",
                    ProcedureOrder = 7,
                },
                new ProcedureInfo()
                {
                    Id = 8,
                    BusinessId = 1,
                    ProcedureName = "购买物品",
                    ProcedureDesc = "执行购买的物品",
                    ProcedureOrder = 8,
                },
                new ProcedureInfo()
                {
                    Id = 9,
                    BusinessId = 1,
                    ProcedureName = "物品清点验收",
                    ProcedureDesc = "确认物品数量与质量",
                    ProcedureOrder = 9,
                },
                new ProcedureInfo()
                {
                    Id = 10,
                    BusinessId = 1,
                    ProcedureName = "现场组装布置",
                    ProcedureDesc = "根据客户要求与现场实际情况进行组装布置",
                    ProcedureOrder = 10,
                }

            );

            // 产品
            modelBuilder.Entity<ProductInfo>().HasData(
                new ProductInfo()
                {
                    Id = 1,
                    ProductPict = "home.png",
                    ProductName = "黑胡桃实木沙发",
                    ProductPrice = 8780
                },
                new ProductInfo()
                {
                    Id = 2,
                    ProductPict = "home.png",
                    ProductName = "云朵棉麻沙发",
                    ProductPrice = 3680
                },
                new ProductInfo()
                {
                    Id = 3,
                    ProductPict = "home.png",
                    ProductName = "全实木红木大床",
                    ProductPrice = 4680
                }
            );
            modelBuilder.Entity<WF_ApprovalFlow>().HasData(
                new WF_ApprovalFlow()
                {
                    Id = 1,
                    TypeCode = 101,
                    TypeName = "订单审批",
                    TypeDesc = "1000以内主管审批就行"

                },
                new WF_ApprovalFlow()
                {
                    Id = 2,
                    TypeCode = 102,
                    TypeName = "订单审批",
                    TypeDesc = "1000-10000以内主管和财务审批"

                },
                new WF_ApprovalFlow()
                {
                    Id = 3,
                    TypeCode = 201,
                    TypeName = "延期审批",
                    TypeDesc = "经理审批"

                },
                new WF_ApprovalFlow()
                {
                    Id = 4,
                    TypeCode = 202,
                    TypeName = "任务转移审批",
                    TypeDesc = "经理审批"

                }
            );
            modelBuilder.Entity<WF_Node>().HasData(
                new WF_Node()
                {
                    Id = 1,
                    TypeCode = 101,
                    NodeCode = 10101,
                    NodeName = "订单-发起审批",
                    RoleName = "管理员",
                    PrevNodeCode = 0,
                    RoleId = 1,
                    IsUseDept = 0,
                    NextNodeCode = 10102
                },
                new WF_Node()
                {
                    Id = 2,
                    TypeCode = 101,
                    NodeCode = 10102,
                    NodeName = "订单-发起审批",
                    PrevNodeCode = 10101,
                    RoleName = "管理员",
                    RoleId = 1,
                    IsUseDept = 1,
                    NextNodeCode = 0
                }
                );
        }
    }
}
